package router

import (
	"gin-vue-admin/api/v1"
	"gin-vue-admin/middleware"
	"github.com/gin-gonic/gin"
)

func InitTailsRouter(Router *gin.RouterGroup) {
	TailsRouter := Router.Group("tails").Use(middleware.OperationRecord())
	{
		TailsRouter.POST("createTails", v1.CreateTails)   // 新建Tails
		TailsRouter.DELETE("deleteTails", v1.DeleteTails) // 删除Tails
		TailsRouter.DELETE("deleteTailsByIds", v1.DeleteTailsByIds) // 批量删除Tails
		TailsRouter.PUT("updateTails", v1.UpdateTails)    // 更新Tails
		TailsRouter.GET("findTails", v1.FindTails)        // 根据ID获取Tails
		TailsRouter.GET("getTailsList", v1.GetTailsList)  // 获取Tails列表
		TailsRouter.GET("getTailsListByLineId", v1.GetTailsListByLineId)  // 根据LineId查询数据列表
		TailsRouter.GET("getTailsByMaxCreateTimeWhereLineId", v1.GetTailsByMaxCreateTimeWhereLineId)  // 根据LineId的最大创建时间查询最新记录
	}
}
